<div id="dicmodal" class="modal" tabindex="-1" role="dialog">
    <div class="modal-dialog">
        <div class="card">
            <div class="header">
                <button type="button" class="close" ng-click="$hide()">&times;</button>
                <h4 class="modal-title">{{params.title}}</h4>
            </div>
            <div activate-input class="body">
                <form class="form-horizontal" role="form" id="dicform"
                      name="dicform" ng-submit="save(dicform.$valid)" novalidate>
                    <div class="row clearfix">
                        <div class="col-lg-3 col-md-3 col-sm-3 col-xs-3 form-control-label">
                            <label>分类名称</label>
                        </div>
                        <div class="col-lg-8 col-md-8 col-sm-8 col-xs-8">
                            <div class="form-group">
                                <div class="form-line"
                                     ng-class="{ 'has-error' : dicform.name.$invalid &&  dicform.$submitted}">
                                    <input type="text" name="name" ng-model="dataModel.name" maxlength="100"
                                           class="form-control"
                                           ng-required="true"/>
                                </div>
                                <label ng-show="dicform.name.$invalid &&  dicform.$submitted"
                                       class="error">必填.
                                </label>
                            </div>
                        </div>
                    </div>
                    <div class="row clearfix">
                        <div class="col-lg-3 col-md-3 col-sm-3 col-xs-3 form-control-label">
                            <label>所属上级</label>
                        </div>
                        <div class="col-lg-8 col-md-8 col-sm-8 col-xs-8">
                            <div class="form-group">
                                <div class="form-line">
                                    <div class="input-group" style="margin-bottom: 0px;">
                                        <input name="parentName" type="text" ng-model="dataModel.parentName"
                                               class="form-control" disabled="disabled"/>
                                        <div class="input-group-addon">
                                            <i ng-click="selectParent()" class="material-icons">search</i>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                    <div class="row clearfix">
                        <div class="col-lg-3 col-md-3 col-sm-3 col-xs-3 form-control-label">
                            <label>是否公开</label>
                        </div>
                        <div class="col-lg-8 col-md-8 col-sm-8 col-xs-8">
                            <div class="form-group">
                                <div class="form-line"
                                     ng-class="{ 'has-error' : dicform.ispublic.$invalid &&  dicform.$submitted}">
                                    <select class="form-control show-tick" name="ispublic" ng-required="true"
                                            ng-model="dataModel.ispublic"
                                            ng-options="it.val as it.name for it in selectList">
                                        <option value="" selected>--请选择--</option>
                                    </select>
                                </div>
                                <label ng-show="dicform.ispublic.$invalid &&  dicform.$submitted"
                                       class="error">必填.</label>
                            </div>
                        </div>
                    </div>
                    <div class="row clearfix">
                        <div class="col-lg-3 col-md-3 col-sm-3 col-xs-3 form-control-label">
                            <label>排序</label>
                        </div>
                        <div class="col-lg-8 col-md-8 col-sm-8 col-xs-8">
                            <div class="form-group">
                                <div class="form-line"
                                     ng-class="{ 'has-error' : dicform.orderby.$invalid &&  dicform.$submitted}">
                                    <input type="number" name="orderby" ng-model="dataModel.orderby"
                                           class="form-control"
                                           ng-required="true"/>
                                </div>
                                <label ng-show="dicform.orderby.$invalid &&  dicform.$submitted"
                                       class="error">必填.</label>
                            </div>
                        </div>
                    </div>
                    <div class="row clearfix">
                        <div class="col-lg-7 col-md-7 col-sm-7 col-xs-7">
                        </div>
                        <div class="col-lg-5 col-md-5 col-sm-5 col-xs-5 foot-btn">
                            <button type="button" class="btn btn-default" ng-click="$hide()">取消</button>
                            <button type="submit" class="btn btn-primary" form="dicform">保存</button>
                        </div>

                    </div>
                </form>
            </div>
        </div>
    </div>
</div>
